package com.cy.Service;

import com.cy.bean.*;
import com.cy.mapper.FronthostMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class FronthostServicelmpl implements FronthostService  {
    @Autowired
    private FronthostMapper fronthostMapper ;
    @Override
    public int insrtUser(String openid, String regtime) {
        return fronthostMapper.insrtUser(openid,regtime);
    }

    @Override
    public int insrtFrontslave(String uid) {
        return fronthostMapper.insrtFrontslave(uid);
    }

    @Override
    public Fronthost selectUserOne(String openid) {
        return fronthostMapper.selectUserOne(openid);
    }

    @Override
    public Fronthost selectUserAll(String openid) {
        return fronthostMapper.selectUserAll(openid);
    }

    @Override
    public int insertFrontReport(Frontreport frontreport) {
        return fronthostMapper.insertFrontReport(frontreport);
    }

    @Override
    public List<Report> selseReportList(String uid) {
        return fronthostMapper.selseReportList(uid);
    }

    @Override
    public List<Fronthost> selectFamily(String uid) {
        return fronthostMapper.selectFamily(uid);
    }

    @Override
    public Fronthost selectFamilyone(String uid) {
        return fronthostMapper.selectFamilyone(uid);
    }

    @Override
    public Fronthost Familyone(String uname, String idnumber) {
        return fronthostMapper.Familyone(uname,idnumber);
    }

    @Override
    public int insertfamily(int uid, int fuid) {
        return fronthostMapper.insertfamily(uid,fuid);
    }

    @Override
    public Family selechongfu(int uid, int fuid) {
        return fronthostMapper.selechongfu(uid,fuid);
    }

    @Override
    public int deleFamily(String uid, String fuid) {
        return fronthostMapper.deleFamily(uid,fuid);
    }

    @Override
    public List<Frontnote> selectFrontnote(String phone, String nowday, String sevenday) {
        return fronthostMapper.selectFrontnote(phone,nowday,sevenday);
    }

    @Override
    public int updateRealName(String uname, String phone, String idnumber, String uid) {
        return fronthostMapper.updateRealName(uname,phone,idnumber,uid);
    }

    @Override
    public Fronthost updateMydata(String uname, String phone, String idnumber, String nativeplace, String nowprovince, String nowcity, String nowarea, String nowaddress, String uid) {
        return fronthostMapper.updateMydata(uname,phone,idnumber,nativeplace,nowprovince,nowcity,nowarea,nowaddress,uid);
    }

    @Override
    public Fronthost selectUserAddress(String uid) {
        return fronthostMapper.selectUserAddress(uid);
    }

    @Override
    public List<Orderrecord> ordlist(String uid) {
        return fronthostMapper.ordlist(uid);
    }
}
